#include<stdio.h>
int main()
{
    long int i;
    long int bonus1,bonus2,bonus3,bonus4,bonus5,bonus;
    printf("please input prifit:");
    scanf("%ld",&i);
    bonus1=100000*0.1;
    bonus2=bonus1+100000*0.075;
    bonus3=bonus2+200000*0.05;
    bonus4=bonus3+200000*0.03;
    bonus5=bonus4+400000*0.015;
    switch(i/100000)
    {
        case 0:i*0.1;break;
        case 1:bonus=bonus1+(i-100000)*0.075;break;
        case 2:
        case 3:bonus=bonus2+(i-200000)*0.05;break;
        case 4:
        case 5:bonus=bonus3+(i-400000)*0.03;break;
        case 6:
        case 7:
        case 8:
        case 9:bonus=bonus4+(i-600000)*0.015;break;
        default:bonus=bonus5+(i-1000000)*0.01;
    }
    printf("bonus=%ld",bonus);
}